<?php

namespace Database\Seeders;

// use Illuminate\Database\Console\Seeds\WithoutModelEvents;
use Illuminate\Database\Seeder;
use App\Models\User;
use App\Models\Blog;
use App\Models\Category;
use App\Models\Comment;

class DatabaseSeeder extends Seeder
{
    /**
     * Seed the application's database.
     *
     * @return void
     */
    public function run()
    {
        User::factory(10)->create();
        $user = User::all()->first();
        $user->update(['email' => 'admin@admin.com']);
        Category::create([
            'name' => 'blog',
            'slug' => 'blog'
        ]);

        Blog::factory(10)->create();
        Comment::factory(30)->create();
    }
}
